import 'package:json_annotation/json_annotation.dart';

part 'scheme_info_detail_data.g.dart';


@JsonSerializable()
class SchemeInfoDetailData extends Object {

  @JsonKey(name: 'authorId')
  int authorId;

  @JsonKey(name: 'authorMobile')
  String authorMobile;

  @JsonKey(name: 'authorName')
  String authorName;

  @JsonKey(name: 'authorPic')
  String authorPic;

  @JsonKey(name: 'buildingArea')
  double buildingArea;

  @JsonKey(name: 'buildingName')
  String buildingName;

  @JsonKey(name: 'collectionNum')
  int collectionNum;

  @JsonKey(name: 'id')
  int id;

  @JsonKey(name: 'image')
  String image;

  @JsonKey(name: 'isCancel')
  int isCancel;

  @JsonKey(name: 'layoutPic')
  String layoutPic;

  @JsonKey(name: 'panoUrl')
  String panoUrl;

  @JsonKey(name: 'position')
  int position;

  @JsonKey(name: 'positionName')
  String positionName;

  @JsonKey(name: 'price')
  int price;

  @JsonKey(name: 'projectTime')
  String projectTime;

  @JsonKey(name: 'schemeName')
  String schemeName;

  @JsonKey(name: 'style')
  String style;

  @JsonKey(name: 'type')
  int type;

  @JsonKey(name: 'url')
  String url;

  @JsonKey(name: 'vrType')
  int vrType;

  @JsonKey(name: 'houseParams')
  HouseParams houseParams;

  SchemeInfoDetailData(this.authorId,this.authorMobile,this.authorName,this.authorPic,this.buildingArea,this.buildingName,this.collectionNum,this.id,this.image,this.isCancel,this.layoutPic,this.panoUrl,this.position,this.positionName,this.price,this.projectTime,this.schemeName,this.style,this.type,this.url,this.vrType,this.houseParams,);

  factory SchemeInfoDetailData.fromJson(Map<String, dynamic> srcJson) => _$SchemeInfoDetailDataFromJson(srcJson);

  Map<String, dynamic> toJson() => _$SchemeInfoDetailDataToJson(this);

}


@JsonSerializable()
class HouseParams extends Object {

  @JsonKey(name: 'balconyNum')
  int balconyNum;

  @JsonKey(name: 'bathroomNum')
  int bathroomNum;

  @JsonKey(name: 'bedroomNum')
  int bedroomNum;

  @JsonKey(name: 'kitchenNum')
  int kitchenNum;

  @JsonKey(name: 'livingRoomNum')
  int livingRoomNum;

  HouseParams(this.balconyNum,this.bathroomNum,this.bedroomNum,this.kitchenNum,this.livingRoomNum,);

  factory HouseParams.fromJson(Map<String, dynamic> srcJson) => _$HouseParamsFromJson(srcJson);

  Map<String, dynamic> toJson() => _$HouseParamsToJson(this);

}


